from task.pageAction.actionmanage import ActionManage
from task.base.driver import Driver
import task.pageObject
class Login(ActionManage):

    def login_success(self):
        self.pageindex.click_login_link()
        self.pagelogin.input_username(task.pageObject.value_login_username)
        self.pagelogin.input_pwd(task.pageObject.value_login_pwd)
        self.pagelogin.click_login()

    def login_business(self,username,pwd):
        self.pageindex.click_login_link()
        self.pagelogin.input_username(username)
        self.pagelogin.input_pwd(pwd)
        self.pagelogin.click_login()


if __name__ == '__main__':

    driver = Driver().get_driver()
    Login(driver).login_success()

